The Apple Events & Scripting Development Kit is intended for developers who are building Apple event-aware applications and supporting Apple's Open Scripting Architecture. All materials contained herein conform to the "Apple Event Registry, Standard Suites, Vers. 1.0", now available from APDA.
This folder contains:
- Pascal, C, and Assmebly interfaces that define constants used in
the Apple Event Registry (located in the Interfaces folder).
- Sample source code that demonstrates the use of the Apple Event
Manager and the Object Support Library and that implements
standard events and objects defined by the Apple Event Registry.
- Testing tools for Apple event-aware applications
- Tools for building, sending, and verifying standard Apple Event
data structures.
- Apple's standard user terminology resource (the 'aeut' resource).
- A tool for building user terminology extension resources for
applications ('aete' resources).
Questions and Answers.
---------------------
Q: I want to incorporate Apple events into my application. Where do I begin?
A: First, become familar with the Apple Event Manager and the Object Model by reading the Apple Event Manager chapter of the new Inside Mac Collaborative Computing volume on the February (or later) Developer CD.
Q: I've read the Apple Event Manager Chapter of Inside Macintosh. I've even read bits and pieces of the Apple Event Registry. I'll go nuts without some sample code! What have you got?
A: AEObject-Edition Sample and CoreSample, both in C. Both demonstrate the implementation of Apple event handlers and object accessors. CoreSample is smaller and conforms to the final Registry. AEObject-Edition Sample has more features and demonstrates more techniques. Quill, written in Pascal, supports the Text Suite in addition to the Required and Core suite of events.
Q: I want to implement Apple Event handlers and Object accessors for standard events and objects defined by the Apple Event Registry. Where are all of the new constants for classes, ids, keywords, and data types defined?
A: AERegistry.h, AERegistry.p, and AERegistry.a.
Q: I've already written some Apple event handlers and object accessors for my application. Now I want to include an 'aete' resource , but it's no fun to build it by hand. Do you have an 'aete' builder?
A: The Aete Editor stack, which requires HyperCard 2.1. (You can find HyperCard 2.1 on the most recent release of the Developer CD Series from the Apple Developer Group.)
Q: How can I test this stuff if there's nobody around to send me the Apple events I handle?
A: The Apple Event XCMDS stack will read your application's 'aete' resource and create routines in HyperTalk or the MPW scripting language that sends the events as described in the 'aete'. You can use these routines to create HyperTalk or MPW scripts for testing.
Q: What tools will help me when I want to do some down and dirty debugging?
A: There's a collection of FKEYs and Macsbug resources (dcmds and macros) that should help. For example, the DebugAEHandler FKEY installs a pre-handler access routine that can drop you into your debugger just before a dispatch to an event handler. It uses the "msg" dcmd to display the current Apple event in human-readable form.
In addition, there's a version of the Object Support Library (OSL + Debug Hack in the Tools folder) that drops into the debugger with a display of useful information just before calling an object accessor function. To use this version of the OSL, simply link it into your application in place of the standard version.